home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d12
/
cc02.arc
/
CLEARSCR.C
< prev
next >
Wrap
Text File
|
1986-03-14
|
896b
|
26 lines
This code was taken from Compuserve
/* clear.c clear the crt
by earl c. terwilliger jr.
05-04-1983
*/
main()
{
struct regval { int ax,bx,cx,dx,si,di,ds,es; };
struct regval srv,rrv;
srv.cx = 0x0f00; /* remove the cursor */
srv.ax = 0x0100; /* set cursor type */
sysint(16,&srv,&rrv);
srv.ax = 0x0600; /* scroll & blank */
srv.cx = 0x0000; /* top left */
srv.dx = 0x184f; /* bottom right */
srv.bx = 0x0700; /* fill attribute */
sysint(16,&srv,&rrv);
sysint(17,&srv,&rrv); /* equipment flag */
srv.bx = srv.ax; /* copy it */
srv.bx = srv.bx & 0x0030; /* mask for video */
if (srv.bx == 0x0030) srv.ax = 0x0007; /* color or bw ? */
else srv.ax = 0x0002;
sysint(16,&srv,&rrv); /* screen back on */
}
0) srv.ax = 0x0007; /* color or bw ? */
else srv.